package com.mind.battle;
import java.util.List;
import java.util.ArrayList;
import com.mind.common.MessageCode;
import com.mind.core.net.msg.BaseMessage;
import java.util.Date;
/**进入战斗房间
*自动生成类
*/
public class EnterBattleRoomMessage extends BaseMessage{
	/**房间id*/
	private Short roomId;
	/***/
	private Float x;
	/***/
	private Float y;
	/***/
	private Short xSpeed;
	/***/
	private Short ySpeed;
	/***/
	private Byte xDriction;
	/***/
	private Byte yDriction;
	public EnterBattleRoomMessage(){}
	public EnterBattleRoomMessage(Short roomId,Float x,Float y,Short xSpeed,Short ySpeed,Byte xDriction,Byte yDriction){
	  this.roomId=roomId;
	  this.x=x;
	  this.y=y;
	  this.xSpeed=xSpeed;
	  this.ySpeed=ySpeed;
	  this.xDriction=xDriction;
	  this.yDriction=yDriction;
	}
	/**获取房间id*/
	public Short getRoomId(){
		return this.roomId;
	}
	/**获取*/
	public Float getX(){
		return this.x;
	}
	/**获取*/
	public Float getY(){
		return this.y;
	}
	/**获取*/
	public Short getXSpeed(){
		return this.xSpeed;
	}
	/**获取*/
	public Short getYSpeed(){
		return this.ySpeed;
	}
	/**获取*/
	public Byte getXDriction(){
		return this.xDriction;
	}
	/**获取*/
	public Byte getYDriction(){
		return this.yDriction;
	}
	public boolean readImpl() {
		this.roomId=readShort();
		this.x=readFloat();
		this.y=readFloat();
		this.xSpeed=readShort();
		this.ySpeed=readShort();
		this.xDriction=readByte();
		this.yDriction=readByte();
		return true;
	}
	public boolean writeImpl() {
		writeShort(this.roomId);
		writeFloat(this.x);
		writeFloat(this.y);
		writeShort(this.xSpeed);
		writeShort(this.ySpeed);
		writeByte(this.xDriction);
		writeByte(this.yDriction);
		return true;
	}
	public short getMessageType() {
		return MessageCode.EnterBattleRoomMessage_CODE;
	}
}
